package de.uni.muenster.idw2.location.bluetooth.service.fingerprinting.images;

public class AbstractImage
{
	/**
	 * The width of the image.
	 */
	protected int width;
	
	/**
	 * The height of the image.
	 */
	protected int height;
	
	/**
	 * The array bitmap image.
	 */
	protected ArrayBitmap arrayBitmap;
	
	/**
	 * Marks the pixel.
	 * 
	 * @param x X position (to the right).
	 * @param y Y position (down).
	 */
	public void markPixel(int x, int y)
	{
		arrayBitmap.markPixel(x, y);
	}
	
	/**
	 * Checks if the pixel is marked.
	 * 
	 * @param x X position (to the right).
	 * @param y Y position (down).
	 * @return True if the pixel is marked. Otherwise false.
	 */
	public boolean isPixelMarked(int x, int y)
	{
		return arrayBitmap.isPixelMarked(x, y);
	}

	/**
	 * Gets the width.
	 * 
	 * @return The width.
	 */
	public int getWidth()
	{
		return width;
	}

	/**
	 * Gets the height.
	 * 
	 * @return The height.
	 */
	public int getHeight()
	{
		return height;
	}
	
	public void unmarkAllPixels(){
		arrayBitmap.unmarkAllPixels();
	}
}
